package uutalk.netcloud.talk.app.ui.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import java.util.List;

import uutalk.netcloud.talk.base.android.BaseFragment;

/**
 * 类描述：
 * 作者：Pengmutian
 * 时间：2018/4/18
 */
public class MainFragmentPagerAdapter extends FragmentPagerAdapter {

    List<BaseFragment> list;

    public MainFragmentPagerAdapter(FragmentManager fm, List<BaseFragment> list) {
        super(fm);
        this.list = list;
    }

    @Override
    public BaseFragment getItem(int position) {
        return list.get(position);
    }

    @Override
    public int getCount() {
        return list.size();
    }
}
